EXAMPLE SOURCE CODES


     This is a small collection of mostly game example source codes. These source codes are made available to help PlayBasic programmers kick start their game programming journey. Looking for more source code / tutorials & media, then remember to visit the PlayBasic Resource board on our forums.

Found #9 items in Source Code category

 Get Array Handle (HandleOf function)

By: Kevin Picone Added: June 27th, 2020

Category: All,Arrays,Source Code

Get Array Handle (HandleOf function)

     This function returns the HANDLE (The unique bank ID) from any Integer array that's passed into it.

PlayBasic Code:
		dim table(100)
		
		print handleof(table())
		
		sync
		waitkey
		
		
		
Psub  HandleOf(me())
EndPsub Me()




COMMANDS USED: DIM | PRINT | SYNC | WAITKEY |




 Run

By: ATLUS Added: April 12th, 2008

Category: All,Misc,Source Code

Download: Login to Download




 Scrolling terrain damage

By: Ian Price Added: November 4th, 2006

Category: All,Misc,Source Code


An update of my "Worms style terrain damage" demo. This one now includes push-scrolling with the mouse. Press RIGHT mouse button to speed up scrolling. Otherwise, it's exactly the same
Download: Login to Download




 Worms style terrain damage

By: Ian Price Added: November 3rd, 2006

Category: All,Misc,Source Code


A simple but effective terrain destruction demo, with particles and user controlled destruction.
Download: Login to Download




 Blend Modes Demo

By: Alex777 Added: June 14th, 2006

Category: All,Misc,Source Code



Demonstrates the common layer (or image) blend modes. Includes an HSL Color Picker and text links for selecting modes. Users are encouraged to alter the code to place their own images in the top & bottom layers.


Download: Login to Download




 Space nebulae generation

By: Thaaks Added: May 23rd, 2006

Category: All,Misc,Source Code


Now you can generate space nebulae.

Works best with sizes that are multiples of 2. Otherwise you might get fragments in the image...

Colors are changeable of course, just replace them in the appropriate lines (easy to find in the code).


Download: Login to Download




 Plasma generation

By: Thaaks Added: May 18th, 2006

Category: All,Misc,Source Code


This is some random plasma generation, based on the midpoint displacement algorithm. I found it mentioned in some LudumDare game source code.

Have a look at my website under Game development for more information.

http://www.haaks.net/gamedevcode/index.html


Download: Login to Download




 Open Ended Die Roller

By: Alex777 Added: May 9th, 2006

Category: All,Misc,Source Code

Implements an open-ended die roller of the sort often found in strategy games and also demonstrates recursion.

Download: Login to Download




Viewing Page [1] of [1]



Want More Source Codes?:



Release Type: The source code & tutorials found on this site are released as license ware for PlayBasic Users. No Person or Company may redistribute any file (tutorial / source code or media files) from this site, without explicit written permission.

 

 
     
 
       

(c) Copyright 2002 / 2024 Kevin Picone , UnderwareDesign.com  - Privacy Policy   Site: V0.99a [Alpha]